package com.example.mybatisplusdemo.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.mybatisplusdemo.model.domain.OrderMain;
import com.example.mybatisplusdemo.model.dto.OrderDTO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 订单详情 Mapper 接口
 * </p>
 *
 * @author lqj
 * @since 2025-07-02
 */
public interface OrderMainMapper extends BaseMapper<OrderMain> {

    List<OrderMain> selectOrdersByUserId(@Param("userId") Long userId);

    int cancelOrder(@Param("orderId") Long orderId);

    List<OrderDTO> selectOrderDTOList();
}
